package io.renren.dao;

import com.baomidou.mybatisplus.mapper.BaseMapper;
import io.renren.entity.ExamTemplateEntity;
import org.apache.ibatis.annotations.Param;

import java.util.Map;

/**
 * 考试模板表
 *
 * @author LANLING
 * @email lanling@gmail.com
 * @date 2018-10-30 14:56:07
 */
public interface ExamTemplateDao extends BaseMapper<ExamTemplateEntity> {
    /***
     * 获取考试信息
     * @param subjectId 科目id
     * @return
     */
    Map<String, Object> getExamInfo(@Param("subjectId") Integer subjectId);

    /***
     * 获取学员的考试次数，剩余次数
     * @param studentId 学员id
     * @param subjectId 科目id
     * @return
     */
    Map<String, Object> getScoreMap(@Param("studentId") Long studentId, @Param("subjectId") Integer subjectId);
}
